home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Source Code / Libraries / WASTE 1.2 / Minimal IC APIs / ICAPI.h < prev    next >
Text File  |  1996-05-19  |  25KB  |  547 lines

  1. /* •••Start Header••• */
  2.  
  3. /* File:         ICAPI.h (intf)
  4.  * Generated by: 1.0d4
  5.  * For:          IC 1.2
  6.  * On:           Monday, 25 September 1995, 19:28:12
  7.  * 
  8.  * This file is part of the Internet Configuration system and
  9.  * is placed in the public domain for the benefit of all.
  10.  */
  11.  
  12. /* •••End Header••• */
  13.  
  14. /*
  15.     IMPORTANT NOTES ABOUT THE C CONVERSION
  16.     --------------------------------------
  17.     
  18.     o Pascal "var" parameters are converted from "var x : y" to "y *x".  This
  19.       means that when you see the parameter "y *x" you should be aware that
  20.             you *cannot pass in nil*.  In future this restriction may be eased,
  21.             especially for the attr parameter to ICGetPref.  Parameters where nil
  22.             is legal are declared using the explicit pointer type, ie "yPtr x".
  23.  
  24.     o Strings are *Pascal* strings.  This means that they must be word aligned.
  25.         MPW and Think C do this automatically.  The last time I check, Metrowerks
  26.         C does not.  If it still doesn't, then IMHO it's a bug in their compiler
  27.         and you should report it to them.
  28.  
  29.     o The canonical Internet Config interface is defined in Pascal.  These
  30.         headers have not been thoroughly tested.  If there is a conflict between
  31.         these headers and the Pascal interfaces, the Pascal should take precedence.
  32. */
  33.  
  34. /* ///////////////////////////////////////////////////////////////////////////////// */
  35.  
  36. #ifndef __ICAPI__
  37. #define __ICAPI__
  38.  
  39. #ifndef __TYPES__
  40. #include <Types.h>
  41. #endif
  42.  
  43. #ifndef __FILES__
  44. #include <Files.h>
  45. #endif
  46.  
  47. #ifndef __ICTYPES__
  48. #include <ICTypes.h>
  49. #endif
  50.  
  51. #ifndef __ICKEYS__
  52. #include <ICKeys.h>
  53. #endif
  54.  
  55. /* ///////////////////////////////////////////////////////////////////////////////// */
  56.  
  57. /* •••Start ICAPI.h••• */
  58.  
  59. /* ***** Starting Up and Shutting Down ***** */
  60.  
  61. pascal ICError ICStart(ICInstance *inst, OSType creator);
  62.   /* Call this at application initialisation. Set creator to your application
  63.    * creator to allow for future expansion of the IC system. Returns
  64.    * inst as a connection to the IC system.
  65.    */
  66.  
  67. pascal ICError ICStop(ICInstance inst);
  68.   /* It is illegal to call this routine inside a ICBegin/End pair.
  69.    * Call this at application initialisation, after which inst
  70.    * is no longer valid connection to IC.
  71.    */
  72.  
  73. /* ***** Specifying a Configuration ***** */
  74.  
  75. pascal ICError ICFindConfigFile(ICInstance inst, short count, ICDirSpecArrayPtr folders);
  76.   /* It is illegal to call this routine inside a ICBegin/End pair.
  77.    * Call to configure this connection to IC.
  78.    * Set count as the number of valid elements in folders.
  79.    * Set folders to a pointer to the folders to search.
  80.    * Setting count to 0 and folders to nil is OK.
  81.    * Searches the specified folders and then the Preferences folder
  82.    * in a unspecified manner.
  83.    */
  84.  
  85. pascal ICError ICFindUserConfigFile(ICInstance inst, ICDirSpec *where);
  86.   /* Requires IC 1.1.
  87.    * It is illegal to call this routine inside a ICBegin/End pair.
  88.    * Similar to ICFindConfigFile except that it only searches the folder
  89.    * specified in where.  If the input parameters are valid the routine
  90.    * will always successful configure the instance, creating an
  91.    * empty configuration if necessary
  92.    * For use with double-clickable preference files.
  93.    */
  94.  
  95. pascal ICError ICGeneralFindConfigFile(ICInstance inst, Boolean search_prefs, Boolean can_create, short count, ICDirSpecArrayPtr folders);
  96.   /* Requires IC 1.2.
  97.    * It is illegal to call this routine inside a ICBegin/End pair.
  98.    * Call to configure this connection to IC.
  99.    * This routine acts as a more general replacement for
  100.    * ICFindConfigFile and ICFindUserConfigFile.
  101.    * Set search_prefs to true if you want it to search the preferences folder.
  102.    * Set can_create to true if you want it to be able to create a new config.
  103.    * Set count as the number of valid elements in folders.
  104.    * Set folders to a pointer to the folders to search.
  105.    * Setting count to 0 and folders to nil is OK.
  106.    * Searches the specified folders and then optionally the Preferences folder
  107.    * in a unspecified manner.
  108.    */
  109.  
  110. pascal ICError ICChooseConfig(ICInstance inst);
  111.   /* Requires IC 1.2.
  112.    * It is illegal to call this routine inside a ICBegin/End pair.
  113.    * Requests the user to choose a configuration, typically using some
  114.    * sort of modal dialog. If the user cancels the dialog the configuration
  115.    * state will be unaffected.
  116.    */
  117.  
  118. pascal ICError ICChooseNewConfig(ICInstance inst);
  119.   /* Requires IC 1.2.
  120.    * It is illegal to call this routine inside a ICBegin/End pair.
  121.    * Requests the user to create a new configuration, typically using some
  122.    * sort of modal dialog. If the user cancels the dialog the configuration
  123.    * state will be unaffected.
  124.    */
  125.  
  126. pascal ICError ICGetConfigName(ICInstance inst, Boolean longname, Str255 name);
  127.   /* Requires IC 1.2.
  128.    * You must specify a configuration before calling this routine.
  129.    * Returns a string that describes the current configuration at a user
  130.    * level. Set longname to true if you want a long name, up to 255
  131.    * characters, or false if you want a short name, typically about 32
  132.    * characters.
  133.    * The returned string is for user display only. If you rely on the
  134.    * exact format of it, you will conflict with any future IC
  135.    * implementation that doesn't use explicit preference files.
  136.    */
  137.  
  138. pascal ICError ICGetConfigReference(ICInstance inst, ICConfigRefHandle ref);
  139.   /* Requires IC 1.2.
  140.    * You must specify a configuration before calling this routine.
  141.    * Returns a self-contained reference to the instance's current
  142.    * configuration.
  143.    * ref must be a valid non-nil handle and it will be resized to fit the
  144.    * resulting data.
  145.    */
  146.  
  147. pascal ICError ICSetConfigReference(ICInstance inst, ICConfigRefHandle ref, long flags);
  148.   /* Requires IC 1.2.
  149.    * It is illegal to call this routine inside a ICBegin/End pair.
  150.    * Reconfigures the instance using a configuration reference that was
  151.    * got using ICGetConfigReference reference. Set the
  152.    * icNoUserInteraction_bit in flags if you require that this routine
  153.    * not present a modal dialog. Other flag bits are reserved and should
  154.    * be set to zero.
  155.    * ref must not be nil.
  156.    */
  157.  
  158. pascal ICError ICSpecifyConfigFile(ICInstance inst, FSSpec *config);
  159.   /* It is illegal to call this routine inside a ICBegin/End pair.
  160.    * For use only by the IC application.
  161.    * If you call this routine yourself, you will conflict with any
  162.    * future IC implementation that doesn't use explicit preference files.
  163.    */
  164.  
  165. /* ***** Getting Information ***** */
  166.  
  167. pascal ICError ICGetSeed(ICInstance inst, long *seed);
  168.   /* You do not have to specify a configuration before calling this routine.
  169.    * You do not have to be inside an ICBegin/End pair to call this routine.
  170.    * Returns the current seed for the IC prefs database.
  171.    * This seed changes each time a non-volatile preference is changed.
  172.    * You can poll this to determine if any cached preferences change.
  173.    */
  174.  
  175. pascal ICError ICGetPerm(ICInstance inst, ICPerm *perm);
  176.   /* You do not have to specify a configuration before calling this routine.
  177.    * Returns the access permissions currently associated with this instance.
  178.    * While applications normally know what permissions they have,
  179.    * this routine is designed for use by override components.
  180.    */
  181.  
  182. pascal ICError ICDefaultFileName(ICInstance inst, Str63 name);
  183.   /* You do not have to specify a configuration before calling this routine.
  184.    * You do not have to be inside an ICBegin/End pair to call this routine.
  185.    * Returns the default file name for IC preference files.
  186.    * Applications should never need to call this routine.
  187.    * If you rely on information returned by this routine yourself,
  188.    * you may conflict with any future IC implementation that doesn't use
  189.    * explicit preference files.
  190.    * The component calls this routine to set up the default IC file name.
  191.    * This allows this operation to be intercepted by a component that has
  192.    * captured us. It currently gets it from the component resource file.
  193.    * The glue version is hardwired to "Internet Preferences".
  194.    */
  195.  
  196. pascal ICError ICGetComponentInstance(ICInstance inst, Ptr *component_inst);
  197.   /* Requires IC 1.2.
  198.    * You do not have to specify a configuration before calling this routine.
  199.    * You do not have to be inside an ICBegin/End pair to call this routine.
  200.    * Returns noErr and the connection to the IC component,
  201.    * if we're using the component.
  202.    * Returns badComponenInstance and nil if we're operating with glue.
  203.    * The component_inst parameter is a universal pointer to avoid
  204.    * us having to include Component.[ph] (which is not available under
  205.    * some development environments) in order to use IC.
  206.    */
  207.  
  208. /* ***** Reading and Writing Preferences ***** */
  209.  
  210. pascal ICError ICBegin(ICInstance inst, ICPerm perm);
  211.   /* You must specify a configuration before calling this routine.
  212.    * It is illegal to call this routine inside a ICBegin/End pair.
  213.    * Starting reading or writing multiple preferences.
  214.    * A call to this must be balanced by a call to ICEnd.
  215.    * Do not call WaitNextEvent between these calls.
  216.    * The perm specifies whether you intend to read or read/write.
  217.    * Only one writer is allowed per instance.
  218.    * Note that this may open resource files that are not closed
  219.    * until you call ICEnd.
  220.    */
  221.  
  222. pascal ICError ICGetPref(ICInstance inst, ConstStr255Param key, ICAttr *attr, Ptr buf, long *size);
  223.   /* You must specify a configuration before calling this routine.
  224.    * If you are getting or setting multiple preferences, you should place
  225.    * these calls within an ICBegin/ICEnd pair.
  226.    * If you call this routine outside of such a pair, it implicitly
  227.    * calls ICBegin(inst, icReadOnlyPerm).
  228.    * Reads the preference specified by key from the IC database to the
  229.    * buffer pointed to by buf and size.
  230.    * key must not be the empty string.
  231.    * If buf is nil then no data is returned.
  232.    * size must be non-negative.
  233.    * attr and size are always set on return. On errors (except icTruncatedErr)
  234.    * attr is set to ICattr_no_change and size is set to 0.
  235.    * size is the actual size of the data.
  236.    * attr is set to the attributes associated with the preference.
  237.    * If this routine returns icTruncatedErr then the other returned
  238.    * values are valid except that only the first size bytes have been
  239.    * return. size is adjusted to reflect the true size of the preference.
  240.    * Returns icPrefNotFound if there is no preference for the key.
  241.    */
  242.  
  243. pascal ICError ICSetPref(ICInstance inst, ConstStr255Param key, ICAttr attr, Ptr buf, long size);
  244.   /* You must specify a configuration before calling this routine.
  245.    * If you are getting or setting multiple preferences, you should place
  246.    * these calls within an ICBegin/ICEnd pair.
  247.    * If you call this routine outside of such a pair, it implicitly
  248.    * calls ICBegin(inst, icReadWritePerm).
  249.    * Sets the preference specified by key from the IC database to the
  250.    * value pointed to by buf and size.
  251.    * key must not be the empty string.
  252.    * size must be non-negative. 
  253.    * If buf is nil then the preference value is not set and size is ignored.
  254.    * If buf is not nil then the preference value is set to the size
  255.    * bytes pointed to by buf.
  256.    * If attr is ICattr_no_change then the preference attributes are not set.
  257.    * Otherwise the preference attributes are set to attr.
  258.    * Returns icPermErr if the previous ICBegin was passed icReadOnlyPerm.
  259.    * Returns icPermErr if current attr is locked, new attr is locked and buf <> nil.
  260.    */
  261.  
  262. pascal ICError ICFindPrefHandle(ICInstance inst, ConstStr255Param key, ICAttr *attr, Handle prefh);
  263.   /* Requires IC 1.2.
  264.    * You must specify a configuration before calling this routine.
  265.    * If you are getting or setting multiple preferences, you should place
  266.    * these calls within an ICBegin/ICEnd pair.
  267.    * If you call this routine outside of such a pair, it implicitly
  268.    * calls ICBegin(inst, icReadWritePerm).
  269.    * This routine effectively replaces ICGetPrefHandle.
  270.    * Reads the preference specified by key from the IC database into
  271.    * a handle, prefh.
  272.    * key must not be the empty string.
  273.    * attr is set to the attributes associated with the preference.
  274.    * You must set prefh to a non-nil handle before calling this routine.
  275.    * If the preference does not exist, icPrefNotFoundErr is returned.
  276.    */
  277.  
  278. pascal ICError ICGetPrefHandle(ICInstance inst, ConstStr255Param key, ICAttr *attr, Handle *prefh);
  279.   /* Requires IC 1.1.
  280.    * You must specify a configuration before calling this routine.
  281.    * If you are getting or setting multiple preferences, you should place
  282.    * these calls within an ICBegin/ICEnd pair.
  283.    * If you call this routine outside of such a pair, it implicitly
  284.    * calls ICBegin(inst, icReadOnlyPerm).
  285.    * This routine is now obsolete. Use ICFindPrefHandle instead.
  286.    * Reads the preference specified by key from the IC database into
  287.    * a newly created handle, prefh.
  288.    * key must not be the empty string.
  289.    * attr is set to the attributes associated with the preference.
  290.    * The incoming value of prefh is ignored.
  291.    * A new handle is created in the current heap and returned in prefh.
  292.    * If the routine returns an error, prefh is set to nil.
  293.    * If the preference does not exist, no error is returned and prefh is set
  294.    * to an empty handle.
  295.    */
  296.  
  297. pascal ICError ICSetPrefHandle(ICInstance inst, ConstStr255Param key, ICAttr attr, Handle prefh);
  298.   /* Requires IC 1.1.
  299.    * You must specify a configuration before calling this routine.
  300.    * If you are getting or setting multiple preferences, you should place
  301.    * these calls within an ICBegin/ICEnd pair.
  302.    * If you call this routine outside of such a pair, it implicitly
  303.    * calls ICBegin(inst, icReadWritePerm).
  304.    * Sets the preference specified by key from the IC database to the
  305.    * value contained in prefh.
  306.    * key must not be the empty string.
  307.    * If prefh is nil then the preference value is not set.
  308.    * If buf is not nil then the preference value is set to the data
  309.    * contained in it.
  310.    * If attr is ICattr_no_change then the preference attributes are not set.
  311.    * Otherwise the preference attributes are set to attr.
  312.    * Returns icPermErr if the previous ICBegin was passed icReadOnlyPerm.
  313.    * Returns icPermErr if current attr is locked, new attr is locked and prefh <> nil.
  314.    */
  315.  
  316. pascal ICError ICCountPref(ICInstance inst, long *count);
  317.   /* You must specify a configuration before calling this routine.
  318.    * You must be inside an ICBegin/End pair to call this routine.
  319.    * Counts the total number of preferences.
  320.    * If the routine returns an error, count is set to 0.
  321.    */
  322.  
  323. pascal ICError ICGetIndPref(ICInstance inst, long n, Str255 key);
  324.   /* You must specify a configuration before calling this routine.
  325.    * You must be inside an ICBegin/End pair to call this routine.
  326.    * Returns the key of the Nth preference.
  327.    * n must be positive.
  328.    * Returns icPrefNotFoundErr if n is greater than the total number of preferences.
  329.    * If the routine returns an error, key is undefined.
  330.    */
  331.  
  332. pascal ICError ICDeletePref(ICInstance inst, ConstStr255Param key);
  333.   /* You must specify a configuration before calling this routine.
  334.    * You must be inside an ICBegin/End pair to call this routine.
  335.    * Deletes the preference specified by key.
  336.    * key must not be the empty string.
  337.    * Returns icPrefNotFound if the preference specified by key is not present.
  338.    */
  339.  
  340. pascal ICError ICEnd(ICInstance inst);
  341.   /* You must specify a configuration before calling this routine.
  342.    * You must be inside an ICBegin/End pair to call this routine.
  343.    * Terminates a preference session, as started by ICBegin.
  344.    * You must have called ICBegin before calling this routine.
  345.    */
  346.  
  347. /* ***** User Interface Stuff ***** */
  348.  
  349. pascal ICError ICEditPreferences(ICInstance inst, ConstStr255Param key);
  350.   /* Requires IC 1.1.
  351.    * You must specify a configuration before calling this routine.
  352.    * You do not have to be inside an ICBegin/End pair to call this routine.
  353.    * Instructs IC to display the user interface associated with editing
  354.    * preferences and focusing on the preference specified by key.
  355.    * If key is the empty string then no preference should be focused upon.
  356.    * You must have specified a configuration before calling this routine.
  357.    * You do not need to call ICBegin before calling this routine.
  358.    * In the current implementation this launches the IC application
  359.    * (or brings it to the front) and displays the window containing
  360.    * the preference specified by key.
  361.    * It may have a radically different implementation in future
  362.    * IC systems.
  363.    */
  364.  
  365. /* ***** URL Handling ***** */
  366.  
  367. pascal ICError ICParseURL(ICInstance inst, ConstStr255Param hint, Ptr data, long len, long *selStart, long *selEnd, Handle url);
  368.   /* Requires IC 1.1.
  369.    * You must specify a configuration before calling this routine.
  370.    * You do not have to be inside an ICBegin/End pair to call this routine.
  371.    * Parses a URL out of the specified text and returns it in a canonical form
  372.    * in a handle.
  373.    * hint indicates the default scheme for URLs of the form "name@address".
  374.    * If hint is the empty string then URLs of that form are not allowed.
  375.    * data points to the start of the text. It must not be nil.
  376.    * len indicates the length of the text. It must be non-negative.
  377.    * selStart and selEnd should be passed in as the current selection of
  378.    * the text. This selection is given in the same manner as TextEdit,
  379.    * ie if selStart = selEnd then there is no selection only an insertion
  380.    * point. Also selStart ≤ selEnd and 0 ≤ selStart ≤ len and 0 ≤ selEnd ≤ len.
  381.    * selStart and selEnd are returned as the bounds of the URL. If the
  382.    * routine returns an error then these new boundaries may be
  383.    * invalid but they will be close.
  384.    * The incoming url handle must not be nil.  The resulting URL is normalised
  385.    * and copied into the url handle, which is resized to fit.
  386.    */
  387.  
  388. pascal ICError ICLaunchURL(ICInstance inst, ConstStr255Param hint, Ptr data, long len, long *selStart, long *selEnd);
  389.   /* Requires IC 1.1.
  390.    * You must specify a configuration before calling this routine.
  391.    * You do not have to be inside an ICBegin/End pair to call this routine.
  392.    * Parses a URL out of the specified text and feeds it off to the
  393.    * appropriate helper.
  394.    * hint indicates the default scheme for URLs of the form "name@address".
  395.    * If hint is the empty string then URLs of that form are not allowed.
  396.    * data points to the start of the text. It must not be nil.
  397.    * len indicates the length of the text. It must be non-negative.
  398.    * selStart and selEnd should be passed in as the current selection of
  399.    * the text. This selection is given in the same manner as TextEdit,
  400.    * ie if selStart = selEnd then there is no selection only an insertion
  401.    * point. Also selStart ≤ selEnd and 0 ≤ selStart ≤ len and 0 ≤ selEnd ≤ len.
  402.    * selStart and selEnd are returned as the bounds of the URL. If the
  403.    * routine returns an error then these new boundaries may be
  404.    * invalid but they will be close.
  405.    * The URL is parsed out of the text and passed off to the appropriate
  406.    * helper using the GURL AppleEvent.
  407.    */
  408.  
  409. /* ***** Mappings Routines *****
  410.  * 
  411.  * Routines for interrogating mappings database.
  412.  * 
  413.  * ----- High Level Routines -----
  414.  */
  415.  
  416. pascal ICError ICMapFilename(ICInstance inst, ConstStr255Param filename, ICMapEntry *entry);
  417.   /* Requires IC 1.1.
  418.    * You must specify a configuration before calling this routine.
  419.    * If you are getting or setting multiple preferences, you should place
  420.    * these calls within an ICBegin/ICEnd pair.
  421.    * If you call this routine outside of such a pair, it implicitly
  422.    * calls ICBegin(inst, icReadWritePerm).
  423.    * Takes the name of an incoming file and returns the most appropriate
  424.    * mappings database entry, based on its extension.
  425.    * filename must not be the empty string.
  426.    * Returns icPrefNotFoundErr if no suitable entry is found.
  427.    */
  428.  
  429. pascal ICError ICMapTypeCreator(ICInstance inst, OSType fType, OSType fCreator, ConstStr255Param filename, ICMapEntry *entry);
  430.   /* Requires IC 1.1.
  431.    * You must specify a configuration before calling this routine.
  432.    * You must be inside an ICBegin/End pair to call this routine.
  433.    * Takes the type and creator (and optionally the name) of an outgoing
  434.    * file and returns the most appropriate mappings database entry.
  435.    * The filename may be either the name of the outgoing file or
  436.    * the empty string.
  437.    * Returns icPrefNotFoundErr if no suitable entry found.
  438.    */
  439.  
  440. /* ----- Mid Level Routines ----- */
  441.  
  442. pascal ICError ICMapEntriesFilename(ICInstance inst, Handle entries, ConstStr255Param filename, ICMapEntry *entry);
  443.   /* Requires IC 1.1.
  444.    * You must specify a configuration before calling this routine.
  445.    * You do not have to be inside an ICBegin/End pair to call this routine.
  446.    * Takes the name of an incoming file and returns the most appropriate
  447.    * mappings database entry, based on its extension.
  448.    * entries must be a handle to a valid IC mappings database preference.
  449.    * filename must not be the empty string.
  450.    * Returns icPrefNotFoundErr if no suitable entry is found.
  451.    */
  452.  
  453. pascal ICError ICMapEntriesTypeCreator(ICInstance inst, Handle entries, OSType fType, OSType fCreator, ConstStr255Param filename, ICMapEntry *entry);
  454.   /* Requires IC 1.1.
  455.    * You must specify a configuration before calling this routine.
  456.    * You do not have to be inside an ICBegin/End pair to call this routine.
  457.    * Takes the type and creator (and optionally the name) of an outgoing
  458.    * file and returns the most appropriate mappings database entry.
  459.    * entries must be a handle to a valid IC mappings database preference.
  460.    * The filename may be either the name of the outgoing file or
  461.    * the empty string.
  462.    * Returns icPrefNotFoundErr if no suitable entry found.
  463.    */
  464.  
  465. /* ----- Low Level Routines ----- */
  466.  
  467. pascal ICError ICCountMapEntries(ICInstance inst, Handle entries, long *count);
  468.   /* Requires IC 1.1.
  469.    * You must specify a configuration before calling this routine.
  470.    * You do not have to be inside an ICBegin/End pair to call this routine.
  471.    * Counts the number of entries in the mappings database.
  472.    * entries must be a handle to a valid IC mappings database preference.
  473.    * count is set to the number of entries.
  474.    */
  475.  
  476. pascal ICError ICGetIndMapEntry(ICInstance inst, Handle entries, long ndx, long *pos, ICMapEntry *entry);
  477.   /* Requires IC 1.1.
  478.    * You must specify a configuration before calling this routine.
  479.    * You do not have to be inside an ICBegin/End pair to call this routine.
  480.    * Gets the ndx'th entry in the mappings database.
  481.    * entries must be a handle to a valid IC mappings database preference.
  482.    * ndx must be in the range from 1 to the number of entries in the database.
  483.    * The value of pos is ignored on input. pos is set to the position of
  484.    * the ndx'th entry in the database and is suitable for passing back
  485.    * into ICSetMapEntry.
  486.    * Does not return any user data associated with the entry.
  487.    */
  488.  
  489. pascal ICError ICGetMapEntry(ICInstance inst, Handle entries, long pos, ICMapEntry *entry);
  490.   /* Requires IC 1.1.
  491.    * You must specify a configuration before calling this routine.
  492.    * You do not have to be inside an ICBegin/End pair to call this routine.
  493.    * Returns the entry located at position pos in the mappings database.
  494.    * entries must be a handle to a valid IC mappings database preference.
  495.    * pos should be 0 to get the first entry. To get the subsequent entries, add
  496.    * entry.total_size to pos and iterate.
  497.    * Does not return any user data associated with the entry.
  498.    */
  499.  
  500. pascal ICError ICSetMapEntry(ICInstance inst, Handle entries, long pos, ICMapEntry *entry);
  501.   /* Requires IC 1.1.
  502.    * You must specify a configuration before calling this routine.
  503.    * You do not have to be inside an ICBegin/End pair to call this routine.
  504.    * Sets the entry located at position pos in the mappings database.
  505.    * entries must be a handle to a valid IC mappings database preference.
  506.    * pos should be either a value returned from ICGetIndMapEntry or a value
  507.    * calculated using ICGetMapEntry.
  508.    * entry is a var parameter purely for stack space reasons. It is not
  509.    * modified in any way.
  510.    * Any user data associated with the entry is unmodified.
  511.    */
  512.  
  513. pascal ICError ICDeleteMapEntry(ICInstance inst, Handle entries, long pos);
  514.   /* Requires IC 1.1.
  515.    * You must specify a configuration before calling this routine.
  516.    * You do not have to be inside an ICBegin/End pair to call this routine.
  517.    * Deletes the mappings database entry at pos.
  518.    * entries must be a handle to a valid IC mappings database preference.
  519.    * pos should be either a value returned from ICGetIndMapEntry or a value
  520.    * calculated using ICGetMapEntry.
  521.    * Also deletes any user data associated with the entry.
  522.    */
  523.  
  524. pascal ICError ICAddMapEntry(ICInstance inst, Handle entries, ICMapEntry *entry);
  525.   /* Requires IC 1.1.
  526.    * You must specify a configuration before calling this routine.
  527.    * You do not have to be inside an ICBegin/End pair to call this routine.
  528.    * Adds an entry to the mappings database.
  529.    * entries must be a handle to a valid IC mappings database preference.
  530.    * The entry is added to the end of the entries database.
  531.    * No user data is added.
  532.    */
  533.  
  534.  
  535. /* •••End ICAPI.h••• */
  536.  
  537. #ifdef __cplusplus
  538. extern "C" {
  539. #endif
  540.  
  541.  
  542. #ifdef __cplusplus
  543. }
  544. #endif /* __cplusplus */
  545.  
  546. #endif
  547.